<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        function Person(name,age){
            this.name = name ; 
            this.age = age ; 
        }
        Person.prototype.fn = function (){
            console.log("走路");
        }
        let zhangsan = new Person("张三",25);
        zhangsan.fn();
        // Object.getPrototypeOf(zhangsan).height = "175cm" ; 
        Object.setPrototypeOf(zhangsan,{height:"175cm"});
        console.log(zhangsan);
        // let obj = {
        //     fn:function(){
        //         console.log(111);
        //     }
        // }
        // let obj1 = {height:"175cm"}
        // obj = obj1;
        // console.log(obj);
    </script>
</body>
</html>